package no.group.gowther.service;

import com.baomidou.mybatisplus.extension.service.IService;
import no.group.gowther.service.dto.*;
import no.group.gowther.service.dto.param.TagCreateDTO;
import no.group.gowther.service.dto.param.TagQueryDTO;
import no.group.gowther.service.dto.param.TagRenameDTO;
import no.group.gowther.dao.entity.Tag;

import java.util.List;
import java.util.Optional;

public interface TagService extends IService<Tag> {
    List<TagDTO> querySubTag(Optional<Long> tagId);

    void rename(TagRenameDTO tagRenameDTO);

    void delete(Long id);

    ListDTO<TagDTO> queryTagFuzzily(TagQueryDTO tagQueryDTO);

    void create(TagCreateDTO tagCreateDTO);

    /**
     * 查询子后代标签
     * @param id 父标签
     * @return 子后代标签
     */
    List<Long> queryDescendantTag(List<Long> id);

    TagDTO queryTab(Long id);
}
